Developer Documentation
PATH  WebObjects 4.5 Documentation > Getting Started With Direct to Java Client

   

Getting the Default XML

After creating your D2WComponent, you need to replace the contents of its .html file with the XML it should return to the controller factory. You don't have to create all the XML by hand. Usually you start with the XML that's generated by default and modify that to suit your needs. To get the default XML, you use the Assistant.

  1. Start the server and client sides of your application and open the Assistant.

  2. Select the XML tab.

    In the form of specifications, the Assistant lists all the requests it can send to the rule system and displays the XML for the selected specification.

    Recall that a specification is a dictionary that specifies all the input to the rule system for it to satisfy a request. A specification includes the request key (under the key "question") and other state information such as task and entity.

    When you select a specification in the XML pane, the Assistant makes the corresponding request to the rule system and then displays the resulting XML.

  3. Select the specification for the select Studio dialog.

    The Assistant orders the specifications by entity name, question, and task; so you can easily locate the select Studio dialog specification by scanning the list for the Studio specifications. The specification for the select Studio dialog looks like this:

    entity = Studio, question = modalDialog, task = select

    When you select the specification, the Assistant updates the text area to contain the corresponding XML.

  4. Save the XML to a file.

    Click the "Save To XML" button on the XML pane. A "Save XML" window opens. You only need to copy the XML from this file, so you can save it to any directory with any file name. After copying the XML, you can delete the file.

  5. Copy the frozen XML and paste it into your D2WComponent's .html file.


© 1999 Apple Computer, Inc. – (Draft. Last updated 05 Jan 00)